using System.Collections;

namespace Melody_Glider.MelodyContent
{
    public static class Duration
    {
        public const double Full = 4;
        public const double Half = 2;
        public const double Quarter = 1;
        public const double Eighth = 0.5;
        public const double Sixteenth = 0.25;

        public static readonly Hashtable Durations = new Hashtable
                                                       {
                                                           {"full", Full},
                                                           {"half", Half},
                                                           {"quarter", Quarter},
                                                           {"eighth", Eighth},
                                                           {"sixteenth", Sixteenth},
                                                           {Full, "full"}, //if I only knew how to get key by value in .NET MF...
                                                           {Half, "half"},
                                                           {Quarter, "quarter"},
                                                           {Eighth, "eighth"},
                                                           {Sixteenth, "sixteenth"},
                                                           {0, Full},
                                                           {1, Half},
                                                           {2, Quarter},
                                                           {3, Eighth},
                                                           {4, Sixteenth}
                                                       };
    }
}